<?php

namespace App\Models;


use Illuminate\Database\Eloquent\Factories\HasFactory;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;
use Jedrzej\Pimpable\PimpableTrait;

class DeliveryService extends Model
{
    //配送员模型
    use HasFactory;
    use PimpableTrait;

    /**
     * 默认排序
     */
    protected $defaultSortCriteria = ['id,desc'];

    /**
     * 可排序字段
     */
    public $sortable = [
        'created_at',
        'id',
        'nickname',
        'work_id',
        'name'
    ];

    /**
     * 可搜索字段
     */
    public $searchable = [
        'nickname',
        'user_id',
        'phone',
        'status',
        'work_id',
        'name',
    ];

    /**
     * @var string[] 可批量赋值字段
     */
    protected $fillable = [
        'user_id',
        'avatar',
        'nickname',
        'phone',
        'status',
        'word_id',
        'password',
        'name'

        ];


}
